﻿#region Using Directives
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
#endregion

namespace Nihongo
{
    public class Particle : ILanguageComponent
    {
        private readonly string _particle;
        private readonly ParticleType _type;
        private readonly string _romaji;

        private Particle(string particle, ParticleType type)
        {
            _particle = particle;
            _type = type;
            _romaji = Nihongo.Romaji.Render(this);
        }

        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle Wa = new Particle("は", ParticleType.SubjectIndicator);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle Ga = new Particle("が", ParticleType.SubjectIndicator);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle Wo = new Particle("を", ParticleType.DirectObjectIndicator);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle Ni = new Particle("に", ParticleType.IndirectObjectIndicator);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle E = new Particle("へ", ParticleType.DestinationIndicator);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle De = new Particle("で", ParticleType.ActionIndicator);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle No = new Particle("の", ParticleType.OwnershipIndicator);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle To = new Particle("と", ParticleType.Connector);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle Ya = new Particle("や", ParticleType.Connector);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle Mo = new Particle("も", ParticleType.Includer);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle Ka = new Particle("か", ParticleType.QuestionMaker);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle Yo = new Particle("よ", ParticleType.Emphasiser);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle Ne = new Particle("ね", ParticleType.AgreementCheck);
        /// <summary>
        /// 
        /// </summary>
        public static readonly Particle Na = new Particle("な", ParticleType.QuasiAdjectiveIndicator);
        
        public ParticleType ParticleType
        {
            get { return _type; }
        }

        public string Kana
        {
            get { return _particle; }
        }

        public string Romaji
        {
            get { return _romaji; }
        }

        public override string ToString()
        {
            return _particle;
        }
    }
}
